package com;

import java.util.Objects;

/**
 * @Classname ztdz
 * @Description TODO
 * @Date 2022/1/13 12:09
 * @Created by 666
 */
public class Account {
    private String custId;//卡号
    private String userName;//名字
    private String passWord;//密码
    private double money;//金额
    private double quotaMoney;//当次取现限额

    public Account() {
    }

    public Account(String custId, String userName, String passWord, double quotaMoney) {
        this.custId = custId;
        this.userName = userName;
        this.passWord = passWord;
        this.money = money;
        this.quotaMoney = quotaMoney;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        Account account = (Account) o;
        return Double.compare(account.money, money) == 0 &&
                Double.compare(account.quotaMoney, quotaMoney) == 0 &&
                Objects.equals(custId, account.custId) &&
                Objects.equals(userName, account.userName) &&
                Objects.equals(passWord, account.passWord);
    }

    @Override
    public String toString() {
        return "ztdz{" +
                "custId='" + custId + '\'' +
                ", userName='" + userName + '\'' +
                ", passWord='" + passWord + '\'' +
                ", money=" + money +
                ", quotaMoney=" + quotaMoney +
                '}';
    }

    @Override
    public int hashCode() {
        return Objects.hash(custId, userName, passWord, money, quotaMoney);
    }

    public String getCustId() {
        return custId;
    }

    public void setCustId(String custId) {
        this.custId = custId;
    }

    public String getUserName() {
        return userName;
    }

    public void setUserName(String userName) {
        this.userName = userName;
    }

    public String getPassWord() {
        return passWord;
    }

    public void setPassWord(String passWord) {
        this.passWord = passWord;
    }

    public double getMoney() {
        return money;
    }

    public void setMoney(double money) {
        this.money = money;
    }

    public double getQuotaMoney() {
        return quotaMoney;
    }

    public void setQuotaMoney(double quotaMoney) {
        this.quotaMoney = quotaMoney;
    }
}
